<template>
  <div>
    <div class="statistic" v-if="dParams.order_by === 'aliyun_ecs'">
      <div>
        <div class="title f14 font-gray">ECS使用数量</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_ecs_num_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">内存使用总计（G）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_ecs_memory_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">CPU使用总计（核）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_ecs_cpu_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">SSD使用总计（GB）</div>
        <div
          class="value f18 font-org fb"
        >{{ curNum.data.aliyun_ecs_disk_size_cloud_ssd_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">高效云盘使用总计（GB）</div>
        <div
          class="value f18 font-org fb"
        >{{ curNum.data.aliyun_ecs_disk_size_cloud_efficiency_total || '0' }}</div>
      </div>
    </div>
    <div class="statistic" v-if="dParams.order_by === 'aliyun_rds'">
      <div>
        <div class="title f14 font-gray">RDS使用数量</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_rds_num_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">内存使用总计（G）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_rds_memory_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">CPU使用总计（核）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_rds_cpu_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">磁盘使用总计（GB）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_rds_storage_total || '0' }}</div>
      </div>
    </div>
    <div class="statistic" v-if="dParams.order_by === 'aliyun_oss'">
      <div>
        <div class="title f14 font-gray">OSS使用数量</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_oss_num_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">储存容量使用总计（GB）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_oss_storage_total || '0' }}</div>
      </div>
    </div>
    <div class="statistic" v-if="dParams.order_by === 'aliyun_slb'">
      <div>
        <div class="title f14 font-gray">SLB使用数量</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_slb_num_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">IP使用总计（个）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_slb_ip_num_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">公网IP使用总计（个）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_slb_public_ip_num_total || '0' }}</div>
      </div>
    </div>
    <div class="statistic" v-if="dParams.order_by === 'aliyun_redis'">
      <div>
        <div class="title f14 font-gray">REDIS使用数量</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_redis_num_total || '0' }}</div>
      </div>
      <div>
        <div class="title f14 font-gray">储存容量使用总计（G）</div>
        <div class="value f18 font-org fb">{{ curNum.data.aliyun_redis_capacity_total || '0' }}</div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: ["curNum", "dParams"]
};
</script>

<style lang="scss" scoped>
.statistic {
  height: 80px;
  border: 1px solid #efefef;
  display: flex;
  justify-content: space-around;
  align-items: center;
  margin-bottom: 20px;
  & > div {
    text-align: center;
    .value {
      margin: 5px 0;
    }
  }
}
</style>